<!doctype html>
{php}
$static = '/static/home/';
{/php}
<!--[if IE 7]> <html lang="en" class="ie7"> <![endif]-->
<!--[if IE 8]> <html lang="en" class="ie8"> <![endif]-->
<!--[if IE 9]> <html lang="en" class="ie9"> <![endif]-->
<!--[if !IE]><!--> <html lang="en"> <!--<![endif]-->
<head>
    <meta charset="utf-8" />
    <title>{$siteConfig['seo_title']}</title>
    <meta name="apple-mobile-web-app-title" content="{$siteConfig['seo_title']}">
    <meta name="viewport" content="initial-scale=1.0, minimum-scale=1.0,maximum-scale=1.0,user-scalable=no,width=device-width">
    <link rel="shortcut icon" href="{$static}images/favicon.ico">
    <link href="{$static}libs/datatables.net-bs4/css/dataTables.bootstrap4.min.css" rel="stylesheet" type="text/css" />
    <link href="{$static}libs/datatables.net-buttons-bs4/css/buttons.bootstrap4.min.css" rel="stylesheet" type="text/css" />
    <link href="{$static}libs/datatables.net-responsive-bs4/css/responsive.bootstrap4.min.css" rel="stylesheet" type="text/css" />
    <link href="{$static}css/bootstrap.min.css" rel="stylesheet" type="text/css" />
    <link href="{$static}css/icons.min.css" rel="stylesheet" type="text/css" />
    <link href="{$static}css/app.min.css" rel="stylesheet" type="text/css" />
    <link href="{$static}css/style.css" rel="stylesheet" type="text/css" />
</head>
<body data-sidebar="dark">
<style type="text/css">
    table tr td {
        vertical-align:middle !important;
    }
</style>
<!-- Begin page -->
<div id="layout-wrapper">

    {include file='public/mine_topbar' /}
    {include file='public/mine_left' /}

    <!-- ============================================================== -->
    <!-- Start right Content here -->
    <!-- ============================================================== -->
    <div class="main-content">

        <div class="page-content">
            <div class="container-fluid">
                <!-- start page title -->
                <div class="row">
                    <div class="col-12">
                        <div class="page-title-box d-flex align-items-center justify-content-between">
                            <h4 class="mb-0 font-size-18">登录日志</h4>

                            <div class="page-title-right">
                                <ol class="breadcrumb m-0">
                                    <li class="breadcrumb-item"><a href="javascript:void(0)">银管家</a></li>
                                    <li class="breadcrumb-item active">登录日志</li>
                                </ol>
                            </div>

                        </div>
                    </div>
                </div>
                <!-- end page title -->

                <div class="row">
                    <div class="col-12">
                        <div class="card">
                            <div class="card-body">
                                <p class="card-title-desc">当前最多展示1000条数据，如果检索当天，起始时间：2020-05-08 结束时间：2020-05-08</p>
                                <form action="{:url('dashboard/loginLog')}">
                                    <div class="row mb-2">
                                        <div class="col-xl-3 col-md-6 padding-5">
                                            起始时间：<input type="text" class="form-control" id="startDate" name="startDate"
                                                        value="{$params['startDate']}" placeholder="请输入起始时间">
                                        </div>
                                        <div class="col-xl-3 col-md-6 padding-5">
                                            结束时间：<input type="text" class="form-control" id="endDate" name="endDate"
                                                        value="{$params['endDate']}" placeholder="请输入结束时间">
                                        </div>
                                        <div class="col-xl-1 col-md-6 padding-5">　　　　
                                            <input type="submit" class="btn btn-primary btn-block" value="搜索"/>
                                        </div>
                                        <div class="col-xl-1 col-md-6 padding-5">　　　　
                                            <a class="btn btn-danger btn-block" href="{:url('dashboard/loginLog')}">清空</a>
                                        </div>
                                    </div>
                                </form>

                                <!-- table展示列表 -->
                                <div class="table-responsive pb-5">
                                    <table id="datatable" class="table table-striped table-bordered">
                                        <thead>
                                        <tr>
                                            <td>编号</td>
                                            <td>用户名</td>
                                            <td>ip</td>
                                            <td>登录域名</td>
                                            <td>创建时间</td>
                                        </tr>
                                        </thead>

                                        <tbody>
                                        {empty name="list"}
                                        <tr>
                                            <td>----</td>
                                            <td>----</td>
                                            <td>----</td>
                                            <td>----</td>
                                            <td>----</td>
                                            <td>----</td>
                                            <td>----</td>
                                        </tr>
                                        {else /}
                                        {foreach name="list" item="vo"}
                                        <tr>
                                            <td>{$key+1}</td>
                                            <td>{$vo.userName}</td>
                                            <td>{$vo.ip}</td>
                                            <td>{$vo.domain}</td>
                                            <td>{$vo.createTime}</td>
                                        </tr>
                                        {/foreach}
                                        {/empty}
                                        </tbody>
                                    </table>
                                </div><!-- table-responsive End -->
                            </div>
                        </div>
                    </div> <!-- end col -->
                </div> <!-- end row -->

            </div> <!-- container-fluid -->
        </div>
        <!-- End Page-content -->
    </div>
    <!-- end main content-->

</div>
<!-- END layout-wrapper -->

<!-- JAVASCRIPT -->
<script src="{$static}libs/jquery/jquery.min.js"></script>
<script src="{$static}libs/bootstrap/js/bootstrap.bundle.min.js"></script>
<script src="{$static}libs/metismenu/metisMenu.min.js"></script>
<script src="{$static}libs/simplebar/simplebar.min.js"></script>
<script src="{$static}libs/node-waves/waves.min.js"></script>
<script src="{$static}libs/layer/layer.js"></script>

<!-- Required datatable js -->
<script src="{$static}libs/datatables.net/js/jquery.dataTables.min.js"></script>
<script src="{$static}libs/datatables.net-bs4/js/dataTables.bootstrap4.min.js"></script>
<script src="{$static}libs/rolldate/rolldate.min.js"></script>

<script type="text/javascript" src="{$static}js/app.js"></script>
<script type="text/javascript">
    $(function () {
        $("#datatable").DataTable({
            searching:false,
        });

        //时间选择器
        new Rolldate({
            el: '#startDate',
            format: 'YYYY-MM-DD',
            beginYear: 2019,
            endYear: 2100
        });
        new Rolldate({
            el: '#endDate',
            format: 'YYYY-MM-DD',
            beginYear: 2019,
            endYear: 2100
        });
    });
</script>
</body>
</html>
